//
//  ConNavigationontroller.m
//  Shengzhuli
//
//  Created by FXGuo on 2017/4/1.
//  Copyright © 2017年 kamangkeji. All rights reserved.
//

#import "ConNavigationontroller.h"

@interface ConNavigationontroller ()

@end

@implementation ConNavigationontroller

- (void)viewDidLoad {
    [super viewDidLoad];
    //是否启用系统的返回
//    self.useSystemBackBarButtonItem = YES;
}

+ (void)initialize
{
    UINavigationBar *navBar = [UINavigationBar appearance];
//    navBar.titleTextAttributes = @{NSForegroundColorAttributeName:[UIColor whiteColor],NSFontAttributeName:[UIFont systemFontOfSize:20]};
    navBar.titleTextAttributes = @{NSForegroundColorAttributeName:[UIColor blackColor],NSFontAttributeName:[UIFont boldSystemFontOfSize:18]};
    
    [[UIBarButtonItem appearance]setBackButtonTitlePositionAdjustment:UIOffsetMake(0,-60) forBarMetrics:UIBarMetricsDefault];
    
    navBar.translucent = NO;
    CGSize imageSize = CGSizeMake(320,64);
    UIGraphicsBeginImageContextWithOptions(imageSize,0, [UIScreen mainScreen].scale);
//    [NavTinColor set];
    [[UIColor whiteColor] set];
    UIRectFill(CGRectMake(0,0, imageSize.width, imageSize.height));
    UIImage *pressedColorImg = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    [navBar setBackgroundImage:pressedColorImg forBarMetrics:UIBarMetricsDefault];
}

@end
